<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
   	<meta charset="utf-8">
	<meta name="keywords" content="" />
	<meta name="description" content="" />
	<meta content="width=device-width, minimum-scale=1,initial-scale=1, maximum-scale=1, user-scalable=1" id="viewport" name="viewport" />
	<meta content="yes" name="apple-mobile-web-app-capable" />
	<meta content="black" name="apple-mobile-web-app-status-bar-style" />
	<meta content="telephone=no" name="format-detection" />
	<link type="text/css" rel="stylesheet" href="../../template/css/com/com.css"/>
	<link type="text/css" rel="stylesheet" href="../../template/css/list/style.css"/>
    <script type="text/javascript" src="../../script/constants.js"></script>
	<script src="../../template/js/jquery.js"></script>
	<script src="../../template/js/com/com.js"></script>
	<script src="../../template/js/com/template.js"></script>
	<script src="../../resource/my.js"></script>
	<script src="../../script/api.js"></script>
  <link rel="stylesheet" href="../../resource/jinsuistyle.css" />
		<style>
   		#wlxx p{padding:10px 5px;}
   		.page-title{margin-bottom:10px;}
   		.pxui-area{margin:5px;}
   	</style>
  </head>
  <body>
   <header id="statusBar">
   <div id="jsheader">
      <nav id="jsnav">
          <a id="jsleft" tapmode="" onclick="api.closeToWin({name: 'root'});">
              <span>主页</span>
          </a>
          <div id="jsmiddle">
              <strong id="jstitle">金穗采购</strong>
          </div>
          <a id="jsright">
            <span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
          </a>
      </nav>
  </div>
  </header>
    <div class="com-content style-page">
		<!-- <div class="com-header-area" id="js-com-header-area">
			<a href="" class="com-header-logo"
				style="width:100%;color:#FFFFFF;text-align:center;font-size:24px;">金穗采购</a>
			<div class="clear"></div>
		</div> -->
		<div class="com-header-area" id="js-com-header-area">
			<!-- <a href="" class="com-header-logo"
				style="width:100%;color:#FFFFFF;text-align:center;font-size:20px;">金穗采购</a> -->
				<img src="../../image/jscg0.png" style="width:100%;"/>
				<ul class="menu_ul">
					<a href="jscg.html" class="selected"><li>首  页</li></a>
					<a href="history.html"><li>历 史 订 单</li></a>
					<a href="bill.html"><li>购 物 框</li></a>
				</ul>
			<dfn></dfn>
			<div class="clear"></div>
		</div> 
		<div class="com-content-area" id="js-com-content-area" style="padding:0px;">
			<!-- <div class="pxui-tab pxui-tab-nav pxui-tab-no-top">
				<a href="main.html"><i></i>首 页<span></span></a>
				<a href="history.html"  class="selected"><i></i>历史订单<span></span></a>
				<a href="bill.html"><i></i>购物筐<span></span></a>
			</div> -->
			<div class="page-role cart-page cart-index-page">
				<div class="page-title">
					<a href="" onclick="closeWin();" class="return">返 回</a>物流查看
				</div>
					<div class="pxui-area goodlist" style="min-height:58%;">
						<div class="pxui-form-info" id="wlxx">
								数据加载中...
						</div>
					</div>
			</div>
		</div>
		<!-- 公共底部，必须引用 -->
		<!-- <div class="com-footer-area" id="js-com-footer-area">
			<div class="com-footer-nav">
				<a href="main.html">首 页</a>
				<a href="history.html">历史订单</a>
				<a href="bill.html">购物筐</a>
			</div>
			<div class="com-footer">
				 © 2012-2018 四川航天金穗高技术有限公司 <br /> All Rights Reserved
				联系电话：028-66778822
			</div>
		</div> -->
			<div class="com-footer-area footer" id="js-com-footer" style="width:100%;">
				<img src="../../image/db.png" style="width:100%;"/>
			</div>
	</div>
  </body>
     	<script type="text/javascript">
     	var _openid = '';
     	apiready = function(){
     	if(api.systemType == "ios"){
		   document.getElementById("statusBar").style.background = "#298cb4";
		}
     	$api.fixStatusBar( $api.dom('header') );
        var header = $api.byId('jsheader');
        if(api.systemType=='ios'){
          $api.fixIos7Bar(header);
        }
//      else{
//        $api.fixStatusBar(header);
//      }

     	  _openid = $api.getStorage('openid');
     	  var orderid = api.pageParam.orderid;
     		wlxx(orderid);
     	}
   	function wlxx(orderid){

   		api.ajax({
		        url:url.wlxx+"?orderid="+orderid+"&openid=" + _openid,
		        method: 'get',
	            cache: 'false',
	            timeout: 30,
	            dataTpye: 'json',
	        }, function(ret,err){
		    	var data = eval("("+ ret.json +")");
		    	console.log(ret.json);
		    	if(data.length == 0){
		    		$("#wlxx").html('<font style="color:red;">没有查询到相关物流信息！</font>');
		    	}else{
		    		var html = "";
		    		for(var i=0;i<data.length;i++){
		    			if(data[i].WLXX.length > 0){
		    				html += "<p>"+ data[i].LOGISTICCODE +  ",物流单号：" + data[i].SHIPPERCODE + "<br/>";
							for(var j=0;j<data[i].WLXX.length;j++){
								html +="<label>"+ data[i].WLXX[j].ACCEPTTIME.substring(0,19)+ " : " + data[i].WLXX[j].ACCEPTSTATION + "</label><br/>";
							}
		    				html += "</p>";
				    	}
		    		}
		    		if(html == ""){
		    			html = "<font style=\"color:red;\">没有查询到相关物流信息！</font>";
		    		}
		    		$("#wlxx").html(html);
		    	}

		    });
   	}


   	function closeWin(){
         api.closeWin();
        }

  	  </script>
</html>
